package net.borlis.server.filesystem.common;

import org.mongodb.morphia.annotations.Entity;

import java.io.Serializable;
import java.math.BigInteger;
import java.security.Timestamp;

/**
 * Created by borlis on 26.12.2014.
 */
@Entity("images")
public class ImageEntry implements Serializable {
    private Long size;
    private String name;
    private String fileType;
    private Timestamp uploaded;
    private Boolean active;
    private BigInteger ownerId;
    private byte[] data;

    public ImageEntry(
            Long size, String name, String fileType, Timestamp uploaded, Boolean active, byte[] data
    ) {
        this.size = size;
        this.name = name;
        this.fileType = fileType;
        this.uploaded = uploaded;
        this.active = active;
        this.data = data;
    }

    public Long getSize() {
        return size;
    }

    public void setSize(Long size) {
        this.size = size;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getFileType() {
        return fileType;
    }

    public void setFileType(String fileType) {
        this.fileType = fileType;
    }

    public Timestamp getUploaded() {
        return uploaded;
    }

    public void setUploaded(Timestamp uploaded) {
        this.uploaded = uploaded;
    }

    public Boolean getActive() {
        return active;
    }

    public void setActive(Boolean active) {
        this.active = active;
    }

    public BigInteger getOwnerId() {
        return ownerId;
    }

    public void setOwnerId(BigInteger ownerId) {
        this.ownerId = ownerId;
    }

    public byte[] getData() {
        return data;
    }

    public void setData(byte[] data) {
        this.data = data;
    }
}
